package com.lin.iotest;

import java.io.File;
import java.io.IOException;
/**
 * 文件类
 * @author Zhang
 *
 */
public class FileDemo {
	public static void createFile(){
		File file = new File("E:/zlnio/createFile.txt");
		try {
			file.mkdirs();
			file.createNewFile();
			System.out.println(file.getName());
			System.out.println(file.getParent());
		} catch (IOException e) {
			e.printStackTrace();
		}
	}
	public static void main(String[] args) {
		createFile();
	}
}
